import { Button } from "antd";

/*
 * @Description:
 * @Version: 2.0
 * @Autor: Seven
 * @Date: 2023-09-21 16:50:14
 * @LastEditors: Seven
 * @LastEditTime: 2023-10-16 10:56:54
 */
export const titleList = [
  {
    id: 1,
    title: "监控告警中心",
    path: "/monitoring",
  },
  {
    id: 2,
    title: "分析决策中心",
    path: "/analyse",
  },
  {
    id: 3,
    title: "运维管理中心",
    path: "/operation",
  },
  {
    id: 4,
    title: "应急管理中心",
    path: "/emergency",
  },
  {
    id: 5,
    title: "安全防护中心",
    path: "/safety",
  },
];
export const knowageList = [
  {
    id: 1,
    title: "室外照明设备检维修安全注意事项",
    tags: ["检维修", "安全注意事项", "照明"],
  },
  {
    id: 2,
    title: "站台板下照明检修(半年)作业指导书",
    tags: ["检维修", "作业指导书", "照明"],
  },
  {
    id: 3,
    title: "3号照明灯带故障",
    tags: ["照明", "故障案列"],
  },
  {
    id: 4,
    title: "室内照明设备检维修安全注意事项",
    tags: ["检维修", "故障案列", "作业指导书"],
  },
];
export const equipList = [
  {
    id: 1,
    title: "检维修",
    num: 3,
  },
  {
    id: 2,
    title: "安全注意事项",
    num: 1,
  },
  {
    id: 3,
    title: "作业指导书",
    num: 1,
  },
  {
    id: 4,
    title: "照明",
    num: 3,
  },
  {
    id: 5,
    title: "故障案例",
    num: 2,
  },
];
// export
export const EquipdataSource = [
  {
    key: "1",
    no: 110201,
    equipName: "恒温器",
    equipType: "恒温器",
    type: "ISO-X3",
    line: 1,
    profession: "信号",
    location: "铁路局站-博物馆站-下行线-K10",
    depart: "通号车间",
    vendor: "美国诺蒂菲尔",
  },
  {
    key: "2",
    no: 110202,
    equipName: "恒温器",
    equipType: "恒温器",
    type: "ISO-X3",
    line: 1,
    profession: "信号",
    location: "哈达站-站厅-132 小系统通风机房",
    depart: "通号车间",
    vendor: "美国诺蒂菲尔",
  },
  {
    key: "3",
    no: 110203,
    equipName: "恒温器",
    equipType: "恒温器",
    type: "ISO-X3",
    line: 1,
    profession: "信号",
    location: "铁路局站-博物馆站-下行线-K10",
    depart: "通号车间",
    vendor: "日本京三",
  },
  {
    key: "4",
    no: 110204,
    equipName: "恒温器",
    equipType: "恒温器",
    type: "ISO-X3",
    line: 1,
    profession: "信号",
    location: "哈达站-站厅-132 小系统通风机房",
    depart: "通号车间",
    vendor: "日本京三",
  },
];
// 故障提报
export const workHandColumns = [
  {
    title: "故障编号",
    dataIndex: "no",
    key: "no",
  },
  {
    title: "故障描述",
    dataIndex: "equipName",
    key: "equipName",
  },
  {
    title: "级别",
    dataIndex: "equipType",
    key: "equipType",
  },
  {
    title: "状态",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "设备",
    dataIndex: "line",
    key: "line",
  },
  {
    title: "车站/区间",
    dataIndex: "profession",
    key: "profession",
  },
  {
    title: "线路",
    dataIndex: "location",
    key: "location",
  },
  {
    title: "专业",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "创建人",
    dataIndex: "vendor",
    key: "vendor",
  },
  {
    title: "发生时间",
    dataIndex: "vendor1",
    key: "vendor1",
  },
  {
    title: "操作",
    dataIndex: "detail",
    key: "detail",
    render: (text, record) => {
      if (record.location.includes("2")) {
        return <Button type="primary">详情</Button>;
      } else {
        return (
          <div>
            <Button type="primary" style={{ marginRight: "5px" }}>
              生成工单
            </Button>
            <Button type="primary">手动处理</Button>
          </div>
        );
      }
    },
  },
];
export const workHanddataSource = [
  {
    key: "1",
    no: 202308100001,
    equipName: "扶梯故障码51",
    equipType: "二级",
    type: "已处理",
    line: "1号出入口自动扶梯",
    profession: "工人文化宫站",
    location: "2号线",
    depart: "机电",
    vendor: "XX用户",
    vendor1: "2023-08-10 09:21:33",
  },
  {
    key: "2",
    no: 202309060001,
    equipName: "全自动车钩紧固件松动",
    equipType: "一级",
    type: "处理中",
    line: "DL5-0502全自动车钩",
    profession: "车辆段",
    location: "1号线",
    depart: "车辆",
    vendor: "自动创建",
    vendor1: "2023-08-10  15:21:33",
  },
  {
    key: "",
    no: 202309060002,
    equipName: "轨道板裂纹",
    equipType: "三级",
    type: "待处理",
    line: "K0+999",
    profession: "工博区间上行",
    location: "2号线",
    depart: "工务",
    vendor: "自动创建",
    vendor1: "2023-08-10  23:21:33",
  },
];
//工单管理
export const workBreakColumns = [
  {
    title: "工单编号",
    dataIndex: "no",
    key: "no",
  },
  {
    title: "工单描述",
    dataIndex: "equipName",
    key: "equipName",
  },
  {
    title: "专业",
    dataIndex: "equipType",
    key: "equipType",
  },
  {
    title: "线路",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "部门",
    dataIndex: "line",
    key: "line",
  },
  {
    title: "车间",
    dataIndex: "profession",
    key: "profession",
  },
  {
    title: "班组",
    dataIndex: "location",
    key: "location",
  },
  {
    title: "创建人",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "创建时间",
    dataIndex: "vendor",
    key: "vendor",
  },
  {
    title: "状态",
    dataIndex: "vendor1",
    key: "vendor1",
  },
  {
    title: "操作",
    dataIndex: "detail",
    key: "detail",
    render: (text, record) => {
      if (record.location.includes("2")) {
        return <Button type="primary">工单完成</Button>;
      } else {
        return (
          <div>
            <Button type="primary">开始检修</Button>
          </div>
        );
      }
    },
  },
];
export const workBreakdataSource = [
  {
    key: "1",
    no: 202308100001,
    equipName: "哈工大FAS模块故障",
    equipType: "机电",
    type: "1号线",
    line: "运营一分公司",
    profession: "机电车间",
    location: "1号线自动化维修工班",
    depart: "XX用户",
    vendor: "2023-08-10 09:21:33",
    vendor1: "初始化",
  },
];
//检修工单
export const workRepairColumns = [
  {
    title: "工单编号",
    dataIndex: "no",
    key: "no",
  },
  {
    title: "工单描述",
    dataIndex: "equipName",
    key: "equipName",
  },
  {
    title: "专业",
    dataIndex: "equipType",
    key: "equipType",
  },
  {
    title: "线路",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "部门",
    dataIndex: "line",
    key: "line",
  },
  {
    title: "车间",
    dataIndex: "profession",
    key: "profession",
  },
  {
    title: "班组",
    dataIndex: "location",
    key: "location",
  },
  {
    title: "创建人",
    dataIndex: "type",
    key: "type",
  },
  {
    title: "创建时间",
    dataIndex: "vendor",
    key: "vendor",
  },
  {
    title: "状态",
    dataIndex: "vendor1",
    key: "vendor1",
  },
  {
    title: "操作",
    dataIndex: "detail",
    key: "detail",
    render: (text, record) => {
      if (record.location.includes("2")) {
        return <Button type="primary">工单完成</Button>;
      } else {
        return (
          <div>
            <Button type="primary">开始检修</Button>
          </div>
        );
      }
    },
  },
];
export const workRepairdataSource = [
  {
    key: "1",
    no: 202308100001,
    equipName: "0128车日检",
    equipType: "车辆",
    type: "1号线",
    line: "运营一分公司",
    profession: "车辆检修车间",
    location: "1号线日检一班1组",
    depart: "XX用户",
    vendor: "2023-08-10 09:21:33",
    vendor1: "初始化",
  },
];
